package comics

import "webcomics/downloader"

// Type used to store the comic information from JSON file
type Comic struct {
	Site       string
	Regex      string
	FileType   string
	PrependURL string
	FullName   string
}

// Downloads the image using information from the Comic
func (c Comic) Download() (img []byte, err error) {
	img, err = downloader.DownloadComic(c.Regex, c.Site, c.PrependURL)
	return
}
